<?php

/*
|--------------------------------------------------------------------------
| admin Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
 */
/* 用户认证路由*/
Route::get('login', 'LoginController@showLoginForm');//登录页面
Route::post('login', 'LoginController@login');//登录逻辑
Route::get('logout', 'LoginController@logout');//登出页面
Route::post('logout', 'LoginController@logout');/*好像没什么用*/
Route::post('checkLogin', 'LoginController@checkLogin');//检查登录
Route::get('register', 'LoginController@register');
Route::get('forgotpassword', 'LoginController@forgotpassword');
//'middleware' => 'adminauth'
Route::group([], function () {

    Route::get('/', function () {
        return view('admin.index.index');
    });

    Route::get('/menu', 'IndexController@menu');
    Route::get('/get/menu', 'IndexController@getMenuApi');
    
    Route::get('/cs', 'IndexController@menu');

    Route::get('/test', function () {
        return view('admin.index.test');
    });

    

    // Route::get('/test','TestController@index');
    // Route::get('/test/st', 'TestController@start');
    // Route::get('/test/res', 'TestController@result');
    Route::get('/helpers/routes', 'RouteController@index');

    Route::get('/user', 'UserController@index');
});
